﻿using System;
using System.Data;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using AnyOffice.Components;
using AnyOffice.DAL;

namespace AnyOffice.general.vehicle.checkup
{
    public partial class delete : ModulePage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            string url = (Request.QueryString["refer"] != null) ? Request.QueryString["refer"].ToString() : "vehicle_wait.aspx";
            int usageId = (Request.QueryString["usage_id"] != null) ? int.Parse(Request.QueryString["usage_id"]) : 0;
            new VehicleUsageDao().Delete(base.Conn, usageId, base.User.Identity.Name, true);
            base.CloseConn();
            Response.Redirect(url);
        } 

    }
}
